package com.usefullc.blog.vo;
import com.usefullc.blog.domain.Category;
import com.usefullc.blog.domain.Tag;
import com.usefullc.common.domain.BaseDomain;
import com.usefullc.system.service.component.extend.ApiField;
import com.usefullc.system.service.component.extend.DictField;
import com.usefullc.system.service.component.extend.EnumField;
import com.usefullc.system.service.component.extend.UsefulField;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.util.Date;
import java.util.List;

/**
 * 文章返回实体
 * @author: 星空
 * @date: 20220628
 */
@Data
public class ArticleVo extends BaseDomain {


//useful_auto_generate_section_start


    @ApiModelProperty(notes = "ID")
    private Long id;


    @ApiModelProperty(notes = "删除状态")
    private Boolean delState;


    @ApiModelProperty(notes = "标题")
    private String title;

    @ApiField(url = "/blog/category/listTree", id = "key", value = "title")
    @ApiModelProperty(notes = "类目")
    private Long categoryId;

    @ApiField(url = "/user/user/listAll", id = "id", value = "userName")
    @ApiModelProperty(notes = "作者")
    private Long userId;

    @EnumField(value = "articleStatusEnum")
    @ApiModelProperty(notes = "状态")
    private Integer status;


    @ApiModelProperty(notes = "内容")
    private String content;

    @UsefulField(format = "yyyy-MM-dd")
    @ApiModelProperty(notes = "修改时间")
    private Date gmtModified;

    @UsefulField(format = "yyyy-MM-dd")
    @ApiModelProperty(notes = "创建时间")
    private Date gmtCreate;

    @UsefulField(format = "yyyy-MM-dd")
    @ApiModelProperty(notes = "发布时间")
    private Date gmtRelease;

    @UsefulField(format = "yyyy-MM-dd")
    @ApiModelProperty(notes = "审核时间")
    private Date gmtAudit;


    @ApiModelProperty(notes = "点赞数")
    private Integer likeNum;


    @ApiModelProperty(notes = "阅读数")
    private Integer readNum;


    @ApiModelProperty(notes = "回复数")
    private Integer replyNum;


    @ApiModelProperty(notes = "分享数")
    private Integer shareNum;


    @ApiModelProperty(notes = "关键字")
    private String keywords;


    @ApiModelProperty(notes = "描述")
    private String description;

    @DictField(value = "yesNoNumber")
    @ApiModelProperty(notes = "投稿")
    private Integer contribution;

    @EnumField(value = "articleContributionStatusEnum")
    @ApiModelProperty(notes = "投稿状态")
    private Integer contributionStatus;

    @DictField(value = "yesNoNumber")
    @ApiModelProperty(notes = "原创")
    private Integer original;

    @EnumField(value = "articleSourceEnum")
    @ApiModelProperty(notes = "来源")
    private Integer source;

    @DictField(value = "yesNoNumber")
    @ApiModelProperty(notes = "开启回复")
    private Integer reply;

    @DictField(value = "yesNoNumber")
    @ApiModelProperty(notes = "置顶")
    private Integer top;

    @DictField(value = "yesNoNumber")
    @ApiModelProperty(notes = "推荐")
    private Integer recommend;


    @ApiModelProperty(notes = "图片")
    private String imgUrl;


    @ApiModelProperty(notes = "文章地址")
    private String url;


//useful_auto_generate_section_end

    @ApiModelProperty(notes = "作者")
    private String author;

    @ApiModelProperty(notes = "头像")
    private String avatar;

    @ApiModelProperty(notes = "类目")
    private Category category;

    @ApiModelProperty(notes = "标签列表")
    private List<String> tags;

//    @ApiModelProperty(notes = "是否点赞")
//    private Integer likeStatus;
//
//    @ApiModelProperty(notes = "是否评论")
//    private Integer replyStatus;

}
